package com.lemon.smartsafety.http.service;

import android.content.Context;

import com.lemon.android.http.LemonRequestParams;
import com.lemon.smartsafety.app.EventTag;
import com.lemon.smartsafety.app.IApplication;
import com.lemon.smartsafety.http.UrlInfo;
import com.lemon.smartsafety.http.callback.HandlerCallback;
import com.zhy.http.okhttp.OkHttpUtils;


/**
 * Created by Cooliean on 16/1/19.
 * 九小场所
 */
public class NineSmallServices extends BaseHttpServices {
    private NineSmallServices(Context context) {
        super(context);
    }

    public static NineSmallServices init() {
        return new NineSmallServices(IApplication.context());
    }
    /**
     * 保存九小场所
     *
     * @return
     */
    public NineSmallServices saveNineSmallInfoAction(LemonRequestParams params) {
        HandlerCallback<String> callback = new HandlerCallback<String>(EventTag.TAG_NINE_SMALL_ACTION) {
        };
        String serverUrl = mSharedPreferencesServer.getRequestUrl(UrlInfo.NINE_SMALL_ACTION);
        OkHttpUtils.post().url(serverUrl).tag(callback.getTag()).params(params).build().execute(callback);
        return this;
    }


}
